<?php
/* @var $this SocialHistoryController */
/* @var $model SocialHistory */
/* @var $form CActiveForm */
?>

<div class="form">

<?php $form=$this->beginWidget('CActiveForm', array(
	'id'=>'social-history-form',
	'enableAjaxValidation'=>false,
)); ?>

	<p class="note">Fields with <span class="required">*</span> are required.</p>

	<?php echo $form->errorSummary($model); ?>

	<div class="row">
		<?php echo $form->labelEx($model,'Do you drive?'); ?>
		<?php echo $form->dropDownList($model,'drive', array('-' => '-','Yes'=>'Yes','No'=>'No')); ?>
		<?php echo $form->error($model,'drive'); ?>
	</div>
	<hr>
	<div class="row">
		<?php echo $form->labelEx($model,'Do you use tobacco Products?'); ?>
		<?php echo $form->dropDownList($model,'tobacco', array('-' => '-','Yes'=>'Yes','No'=>'No')); ?>
		<?php echo $form->error($model,'tobacco'); ?>
	</div>
	<div class="row">
		<?php echo $form->labelEx($model,'If yes, what type?'); ?>
		<?php echo $form->textField($model,'tobacco_type',array('size'=>60,'maxlength'=>300)); ?>
		<?php echo $form->error($model,'tobacco_type'); ?>
	</div>

	<div class="row">
		<?php echo $form->labelEx($model,'If yes, in what amounts?'); ?>
		<?php echo $form->textField($model,'tobacco_ammount'); ?>
		<?php echo $form->error($model,'tobacco_ammount'); ?>
	</div>

	<div class="row">
		<?php echo $form->labelEx($model,'If yes, for how long?'); ?>
		<?php echo $form->textField($model,'tobacco_long',array('size'=>20,'maxlength'=>20)); ?>
		<?php echo $form->error($model,'tobacco_long'); ?>
	</div>
	<hr>
		<div class="row">
		<?php echo $form->labelEx($model,'Do you use illegal drugs?'); ?>
		<?php echo $form->dropDownList($model,'illegal_drug', array('-' => '-','Yes'=>'Yes','No'=>'No')); ?>
		<?php echo $form->error($model,'illegal_drug'); ?>
	</div>

	<div class="row">
		<?php echo $form->labelEx($model,'If yes, what type?'); ?>
		<?php echo $form->textField($model,'drug_type',array('size'=>60,'maxlength'=>300)); ?>
		<?php echo $form->error($model,'drug_type'); ?>
	</div>

	<div class="row">
		<?php echo $form->labelEx($model,'If yes, in what amounts?'); ?>
		<?php echo $form->textField($model,'drug_ammount'); ?>
		<?php echo $form->error($model,'drug_ammount'); ?>
	</div>

	<div class="row">
		<?php echo $form->labelEx($model,'If yes, for how long?'); ?>
		<?php echo $form->textField($model,'drug_long',array('size'=>20,'maxlength'=>20)); ?>
		<?php echo $form->error($model,'drug_long'); ?>
	</div>
	<hr>
	<div class="column">
		<?php echo $form->labelEx($model,'Have you ever been exposed to or infected with: gonorrhea'); ?>
		<?php echo $form->dropDownList($model,'gonorrhea', array('-' => '-','Yes'=>'Yes','No'=>'No')); ?>
		<?php echo $form->error($model,'gonorrhea'); ?>
	</div>

	<div class="row">
		<?php echo $form->labelEx($model,'Have you ever been exposed to or infected with: hepatitis'); ?>
		<?php echo $form->dropDownList($model,'hepatitis', array('-' => '-','Yes'=>'Yes','No'=>'No')); ?>
		<?php echo $form->error($model,'hepatitis'); ?>
	</div>

	<div class="column">
		<?php echo $form->labelEx($model,'Have you ever been exposed to or infected with: syphills'); ?>
		<?php echo $form->dropDownList($model,'syphills', array('-' => '-','Yes'=>'Yes','No'=>'No')); ?>
		<?php echo $form->error($model,'syphills'); ?>
	</div>

	<div class="row">
		<?php echo $form->labelEx($model,'Have you ever been exposed to or infected with: hiv'); ?>
		<?php echo $form->dropDownList($model,'hiv', array('-' => '-','Yes'=>'Yes','No'=>'No')); ?>
		<?php echo $form->error($model,'hiv'); ?>
	</div>
<br>	
	<hr>

	<div class="row">
		<?php echo $form->labelEx($model,'Patient Name'); ?>
		<?php echo $form->dropDownList($model,'personalinfo_id', CHtml::listData(
                PersonalInformation::model() ->findAll(), 'id','fname','lname'), array('prompt' => 'Select Personal Information')); 
                ?>
		<?php echo $form->error($model,'personalinfo_id'); ?>
	</div>

	<div class="row buttons">
		<?php echo CHtml::submitButton($model->isNewRecord ? 'Create' : 'Save'); ?>
	</div>

<?php $this->endWidget(); ?>

</div><!-- form -->